package automatagen;

import java.util.ArrayList;
import java.util.HashMap;

public class MethodDefinition {
    private HashMap<String,Automata> automatas = new HashMap<String,Automata>();
	private HashMap<String, RegisterMap> registers = new HashMap<String, RegisterMap>(); 
	
	public void addAutomata(Automata automata){
	    this.automatas.put(automata.getService(),automata);
	}
	
	public void addRegister(RegisterMap registerMap){
		this.registers.put(registerMap.getName(), registerMap);
	}
	
    public HashMap<String,Automata> getAutomatas() {
		return this.automatas;
	}

	public void setAutomatas(HashMap<String, Automata> automatas) {
		this.automatas = automatas;
	}

	public HashMap<String,RegisterMap> getRegisters() {
		return registers;
	}

	public MethodDefinition() {
		automatas = new HashMap<String, Automata>();
		registers = new HashMap<String,RegisterMap>();
	}
	
    public MethodDefinition(HashMap<String,Automata> automatas, HashMap<String,RegisterMap> registers) {
		this.automatas = automatas;
		this.registers = registers;
	}
	
    /*public MethodDefinition(HashMap<String,Automata> automatas) {
		this.automatas = automatas;
		}*/
	
	public MethodDefinition(HashMap<String,RegisterMap> registers) {
		this.registers = registers;
	}

	public void setRegisters(HashMap<String, RegisterMap> registers) {
		this.registers = registers;
	}
}
